<?php

use think\migration\Migrator;
use think\migration\db\Column;

class CreateAuthGroup extends Migrator
{
    public function up(){
        $table = $this->table('auth_group', ['signed' => false, 'comment' => '用户组表']);
        $table->addColumn('group_name', 'string', ['limit' => 100, 'default' => '', 'comment' => '组名'])
            ->addColumn('status', 'string', ['limit' => 30, 'default' => '', 'comment' => '状态'])
            ->addColumn('menu_auth', 'text', ['comment' => '菜单权限'])
            ->addColumn('remark', 'string', ['limit' => 255, 'default' => '', 'comment' => '描述'])
            ->addColumn('create_time', 'integer', ['limit' => 10, 'default' => 0, 'comment' => '创建时间'])
            ->addColumn('update_time', 'integer', ['limit' => 10, 'default' => 0, 'comment' => '更新时间'])
            ->create();

    }

    public function down()
    {

    }
}
